import React from "react";
import { DualAxes } from "@ant-design/charts";
const BarChart = () => {
    var data = [
        {
            time: "44周",
            "金额/元": 350,
            "下单转化率": 400
        },
        {
            time: "45周",
            "金额/元": 900,
            "下单转化率": 500
        },
        {
            time: "46周",
            "金额/元": 300,
            "下单转化率": 400
        },
        {
            time: "47周",
            "金额/元": 450,
            "下单转化率": 380
        },
        {
            time: "48周",
            "金额/元": 470,
            "下单转化率": 400
        },
        {
            time: "49周",
            "金额/元": 570,
            "下单转化率": 450
        }
    ];
    var config = {
        data: [data, data],
        xField: "time",
        yField: ["金额/元", "下单转化率"],
        geometryOptions: [
            {
                geometry: "column",
                color: "l(90) 0:#f5315f 1:#784af6",
                columnStyle: {
                    radius: [15, 15, 15, 15]
                },
                maxColumnWidth: 30
            },
            {
                geometry: "line",
                lineStyle: { lineWidth: 2 },
                color: "#fed530"
            }
        ]
    };
    return <DualAxes {...config}/>;
};
export default BarChart;